package com.yaoli.Proxy;

/**
 * Created by siemens on 6/1/2017.
 */
public class CountProxy implements Count {
    private Count count;

    public CountProxy(Count count){
        this.count = count;
    }
    @Override
    public void queryCount() {
        System.out.println("更新方法之前");
        count.queryCount();
        System.out.println("更新方法之后");
    }

    @Override
    public void updateCount() {
        System.out.println("before update");
        count.updateCount();
        System.out.println("update update");
    }
}
